package com.threez.gateway.enums;

import com.threez.core.exception.enums.BaseExceptionEnums;
import lombok.AllArgsConstructor;

/**
 * @author zhaozz
 * @title GatewayExceptionEnum
 * @date 2023/1/14 17:05
 */
@AllArgsConstructor
public enum GatewayExceptionEnum implements BaseExceptionEnums {
    JCAPTCHA_NOT_BLANK("20011", "验证码不能为空"),
    USER_JCAPTCHA_EXPIRE("20011", "验证码已失效"),
    USER_JCAPTCHA_ERROR("20011", "验证码已失效"),
    TOKEN_IS_NULL("10101", "未能读取到有效Token"),
    TOKEN_INVALID("10102", "Token无效"),
    TOKEN_OVERDUE("10103", "Token已过期"),
    TOKEN_REPLACE("10104", "Token已被顶下线"),
    TOKEN_KICK_LINE("10105", "Token已被踢下线"),
    TOKEN_SESSION_NOT_LOGIN("10106", "当前会话未登录");

    ;
    private String code;
    private String msg;

    @Override
    public String getCode() {
        return code;
    }

    @Override
    public void setCode(String code) {
        this.code = code;
    }

    @Override
    public String getMsg() {
        return msg;
    }

    @Override
    public void setMsg(String msg) {
        this.msg = msg;
    }

    @Override
    public String getModuleName() {
        return null;
    }
}
